import {createSlice} from "@reduxjs/toolkit";
import useSetStorage from "@/hooks/useSetStorage";

export const aiOriginalitySlice = createSlice({
    name: "login",
    initialState: () => {
        return {
            params: {},
            SYZLParams: {},
            result: [],
            storageData: {},
            storageData1: {},
            editData: {}
        };

    },
    reducers: {
        set_params(state,action){
            state.params = action.payload
        },
        set_SYZLParams(state,action){
            state.SYZLParams = action.payload
        },
        set_result(state,action){
            state.result = action.payload
        },
        set_storageData(state,action){
            state.storageData = action.payload
        },
        set_storageData1(state,action){
            state.storageData1 = action.payload
        },
        set_editData(state,action){
            state.editData = action.payload
        }
    }
});

export const {
    set_params,
    set_SYZLParams,
    set_result,
    set_storageData,
    set_storageData1,
    set_editData
} = aiOriginalitySlice.actions;